perm filename PASNOT.EJG[UP,DOC]1 blob
sn#329930 filedate 1978-01-21 generic text, type T, neo UTF8
***********************************************************************
* Note: this file is set for append access. Please append *
* your comments when you try the Pascal compiler. Just say: *
* @APP TTY: DOC:PASCAL.NOTES *
* and then type your comments, ending with a ↑Z. *
***********************************************************************
SUBJECT: Pascal compiler observations.
Observations on the Pascal compiler.
(as made by J.JHENN)
1. In @EXECUTE mode the /list option causes the listing to appear
on the line printer. This does not happen in @PASCAL mode.
2. In @PASCAL mode:
If /LIST is specified, LIST FILE must be.
/CREF after the source file causes CROSS REFERENCE, with the
following properties:
A * is printed to which you give the name of the source
file without extension.
The list file (.LST) contains pretty printed listing
and cross reference. The file with the source
name and extension .NEW is a formatted listing.
3. The compiler utilizes PPN, which is no problem, if you use
your own directory.
4. On the run time environment.
Using READ/WRITE. To get TTY (i.e. the teletype), use
TTY as the file name. The default file names are INPUT for READ/READLN,
and OUTPUT for WRITE/WRITELN. MESSAGE is always sent to TTY.
5. When the compiler starts using TTY. It first prints a *,
prompting to fill the input buffer. Note that this occurs
prior to executing other statements (including writes
which are before your reads). No big deal --
just enter CR and then continue as usual.
END OF OBSERVATIONS.
-----------------------------------------------------------------------
A.ARMANDO, 01/12/78
Important details that are easy to forget and will give you problems:
1.- If you forget to put a star (*) after the names of any parameter
file which is going to be used for input, it will be rewritten,
instead of reset. This causes a new,empty version of the file
to be created, and your input is not accessible anymore. The
program will stop with the message INPUT DATA ERROR IN FILE ...
when the first input is attempted.
2.- If you give a device name, such as TTY: to the prompt for the
actual names of the parameter files, no error message will be
sent, but your description will be ignored, and the file name
will be assigned in the same way as if you hit return only.
3.- Remember the way a real number is defined. If your program needs
a real number as input, and at run time it takes a number such
as .3 or 456 or 23., it will report an INPUT DATA ERROR IN FILE ...
They should be typed as 0.3 and 456.0 and 23.0 .
4.- When you are prompted for the file names for files INPUT and
OUTPUT, the only extensions allowed are INP and OUT respectively,
and the name of the file should not exceed six characters. So,
AA.INP is a valid file name for INPUT, but ANY.THING and
LONGNAME.INP are not. For other parameter files, the only res-
triction is size: up to 6 chars for the name, and up to 3 for
the extension.
5.- If you use READLN on TTY, then at runtime you will have to type
two <RETURN> instead of one. The first is taken as the end-of-line
character, and the second indicates end of input, as usual.
-----------------------------------------------------------------------
On the USE of INPUT and OUTPUT as standard files.
(observations by J.JHENN)
The standard files INPUT and OUTPUT are predeclared as TEXTFILES,
by the compiler. They operate in two different ways.
First, if the files INPUT and OUTPUT appear in the file header,
then there names are prompted for. They act as described
in the previous note (by A.ARMANDO).
If the file names INPUT and OUTPUT do not appear in the file
header. Then the files will have the names INPUT.. and OUTPUT..
respectively. Additionally, both files will be reset and the
file OUTPUT.. will be rewritten (i.e. a new creation if it
already exists - otherwise a new file). This is equivalent
to putting INPUT*,OUTPUT in the file header and replying to the prompt
INPUT= input..
OUTPUT= output..
__________________________________________________________________
A.ARMANDO 01/17/78
Another warning: INPUT and OUTPUT are predeclared for you by
PASCAL, so they SHOULD NOT EVER be included by you in a VAR
declaration. If you declare them, for some unknown reason they
end up being declared to the system as BINARY, and you will not
be able to read characters from INPUT.
----------------------------------------------------------------------